namespace Sample.Domain
{
    public static class HashCodeGenerator
    {
        public static int GenerateHashCode(params object[] keys)
        {
            int hash = 17;

            foreach (var item in keys)
            {
                int itemHashCode = item == null ? 1 : item.GetHashCode();
                hash = hash * 23 + itemHashCode;
            }

            return hash;
        }
    }
}